package org.acra.d;

import java.util.Collection;
import java.util.Iterator;
import java.util.LinkedList;

public class a extends LinkedList
{
  private final int a;

  public a(int paramInt)
  {
    this.a = paramInt;
  }

  public void add(int paramInt, Object paramObject)
  {
    if (size() == this.a)
      removeFirst();
    super.add(paramInt, paramObject);
  }

  public boolean add(Object paramObject)
  {
    if (size() == this.a)
      removeFirst();
    return super.add(paramObject);
  }

  public boolean addAll(int paramInt, Collection paramCollection)
  {
    throw new UnsupportedOperationException();
  }

  public boolean addAll(Collection paramCollection)
  {
    int i = size() + paramCollection.size() - this.a;
    if (i > 0)
      removeRange(0, i);
    return super.addAll(paramCollection);
  }

  public void addFirst(Object paramObject)
  {
    throw new UnsupportedOperationException();
  }

  public void addLast(Object paramObject)
  {
    add(paramObject);
  }

  public String toString()
  {
    StringBuilder localStringBuilder = new StringBuilder();
    Iterator localIterator = iterator();
    while (localIterator.hasNext())
      localStringBuilder.append(localIterator.next().toString());
    return localStringBuilder.toString();
  }
}

/* Location:           D:\Studium\Bachelorarbeit\BA Marcus Wobig\BA\BA\Decompiler\PicturePassword APK\Programm\PicturePassword_dex2jar.jar
 * Qualified Name:     org.acra.d.a
 * JD-Core Version:    0.6.2
 */